function drawMenuItem(canvas) {
    <!--Clear canvas for redraw-->
    canvas.width = canvas.width;
    var context=canvas.getContext("2d");
    context.font="25px Arial";
    var metrics = context.measureText(canvas.getAttribute("data-name"));
    context.canvas.width = metrics.width;
    context.font="25px Arial";
    context.strokeText(canvas.getAttribute("data-name"),0,30);
}

function drawClickedMenuItem(canvas) {
    <!--Clear canvas for redraw-->
    canvas.width = canvas.width;
    var ctx=canvas.getContext("2d");
    ctx.font="25px Arial";
    ctx.fillText(canvas.getAttribute("data-name"),0,30);
}